package net.sx.minemodule.mvp.item;

import com.homegoods.classify.model.Constant;
import com.kedll.library.adapter.MultiTypeAdapter;
import com.kedll.library.mvp.BaseItem;

import net.sx.minemodule.R;
import net.sx.minemodule.mvp.bean.MyFansBean;

public class MyFansItem extends BaseItem<MyFansBean> {

    public MyFansItem(MyFansBean data, MultiTypeAdapter adapter) {
        super(data);
        setOnClickListener(v -> {
            if (adapter.getOnItemClickListener() != null) {
                adapter.getOnItemClickListener().onItemClicked(v, this);
            }
        });
    }

    public String getHeadPath() {
        return Constant.SERVER_URL + getData().getBgimg();
    }

    public String getName() {
        return getData().getName();
    }

    @Override
    public int getLayout() {
        return R.layout.mine_item_myfans;
    }
}
